package com.cap.dreamcircle.Api;

import com.cap.dreamcircle.Model.Bean.AnonymousResponseBean;
import com.cap.dreamcircle.Model.Bean.BaseBean;
import com.cap.dreamcircle.Model.Bean.UserInfoBean;

import java.util.HashMap;
import java.util.Map;

import okhttp3.RequestBody;
import retrofit2.http.FieldMap;
import retrofit2.http.FormUrlEncoded;
import retrofit2.http.Multipart;
import retrofit2.http.POST;
import retrofit2.http.PartMap;
import rx.Observable;

/**
 * Created by liucxu on 2017/7/11.
 */

public interface UserService {

    @FormUrlEncoded
    @POST("user.do")
    Observable<AnonymousResponseBean> CreateAnonymousUser(@FieldMap HashMap<String,String> params);

    @FormUrlEncoded
    @POST("user.do")
    Observable<BaseBean> GetVerificationCode(@FieldMap HashMap<String,String> params);


    @FormUrlEncoded
    @POST("user.do")
    Observable<AnonymousResponseBean> CreatePhoneUserAccount(@FieldMap HashMap<String,String> params);

    @FormUrlEncoded
    @POST("user.do")
    Observable<AnonymousResponseBean> PhoneLogin(@FieldMap HashMap<String,String> params);

    @Multipart
    @POST("user.do")
    Observable<BaseBean> CompleteUserInfo(@PartMap Map<String, RequestBody> params);

    @FormUrlEncoded
    @POST("user.do")
    Observable<BaseBean> BindUserPhone(@FieldMap HashMap<String,String> params);

    @FormUrlEncoded
    @POST("user.do")
    Observable<BaseBean> BindUserPhoneTest(@FieldMap HashMap<String,String> params);

    @Multipart
    @POST("user.do")
    Observable<AnonymousResponseBean> wechatLogin(@PartMap Map<String, RequestBody> params);

    @FormUrlEncoded
    @POST("user.do")
    Observable<BaseBean> BindWechat(@FieldMap HashMap<String,String> params);

    @FormUrlEncoded
    @POST("user.do")
    Observable<BaseBean> TestTokenValidate(@FieldMap HashMap<String,String> params);

    @FormUrlEncoded
    @POST("user.do")
    Observable<UserInfoBean> RequestUserInfo(@FieldMap HashMap<String,String> params);

    @FormUrlEncoded
    @POST("user.do")
    Observable<BaseBean> CountKey(@FieldMap HashMap<String,String> params);

    @FormUrlEncoded
    @POST("user.do")
    Observable<BaseBean> TestBindWechat(@FieldMap HashMap<String,String> params);

    @Multipart
    @POST("user.do")
    Observable<BaseBean> DoBindWechat(@PartMap Map<String, RequestBody> params);

    @FormUrlEncoded
    @POST("user.do")
    Observable<BaseBean> BindVerificationCode(@FieldMap HashMap<String,String> params);

    @FormUrlEncoded
    @POST("user.do")
    Observable<BaseBean> BindPhoneWithCode(@FieldMap HashMap<String,String> params);
}
